
<%@ page import="java.util.List" %>
<%@ page import="cm.NewsDao.NewsDao1" %>
<%@ page import="cm.NewsDaoImpl.NewsDaoImpl1" %>
<%@ page import="cm.entity.News1" %><%--
  Created by IntelliJ IDEA.
  User: 31052
  Date: 2022/4/6
  Time: 12:17
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>user表</title>
</head>
<body>
<%

    NewsDao1 newsDao1 = new NewsDaoImpl1();
    List<News1> newsList = newsDao1.getNewsList();
%>
    <div>
        <table>
            <%
                for (int i=0;i<newsList.size();i++) {
            %>
            <tr>
                <td>
                    <%=newsList.get(i).getId()%>
                </td>
                <td>
                    <%=newsList.get(i).getCategoryId()%>
                </td>

                <td>
                    <%=newsList.get(i).getTitle()%>
                </td>

                <td><a href="DeleteManege.jsp?newsid=<%=newsList.get(i).getId()%>">删除</a></td>
                <td><a href="UpdateManege.jsp?newsid=<%=newsList.get(i).getId()%>">修改</a></td>
                <td><a href="InsertManege.jsp?newsid=<%=newsList.get(i).getId()%>">添加</a></td>
    </tr>
    <%
      }
    %>
  </table>
</div>
</body>
</html>
